# Copyright (c) 2006-2008, The RubyCocoa Project.
# Copyright (c) 2001-2006, FUJIMOTO Hisakuni.
# All Rights Reserved.
#
# RubyCocoa is free software, covered under either the Ruby's license or the 
# LGPL. See the COPYRIGHT file for more information.

module OSX

  # NSImage additions
  class NSImage
    def focus
      lockFocus
      begin
        yield
      ensure
        unlockFocus
      end
    end
  end
end
